package part1.api.io;

import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;

/**
 * 将所有小写字母写入到文件fos.txt中
 */
public class Test {
    public static void main(String[] args) throws IOException {
        FileOutputStream fos= new FileOutputStream("fos.txt");
        for (int i = 0; i < 26; i++) {
            fos.write(97+i);
        }
        System.out.println("写入完毕");

        FileInputStream fis = new FileInputStream("fos.txt");
//        int a = fis.read();
//        System.out.println(a);
//        char b =9;
//        System.out.println(b);
//        fos.write(b);
        fos.close();
        fis.close();
    }
}
